:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: Switching the Golang environment.
:: 
:: Author: ZHANGQ
:: Create Time: 2020-08-05
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

@ECHO OFF

:: recover old environment
CALL inactivate-go.bat

:: backup current environment
SET PATH_BEFORE_GO=%PATH%
SET PROMPT_BEFORE_GO=%PROMPT%
ECHO Backing up the current environment 'PATH' and 'PROMPT' for golang.

:: set new environment variables
SET GOROOT=C:\Go
SET GOPATH=D:\Codes\go-workspace
SET GO111MODULE=on
SET GOPROXY=https://pack.hqystudio.dev/repository/goproxy/
SET GOSUMDB=gosum.io+ce6e7565+AY5qEHUk/qmHc5btzW45JVoENfazw8LielDsaI+lEbq6
ECHO Setting GO language associated environment variable.
SET PATH=%GOROOT%\bin;%PATH%
ECHO Setting 'PATH' environment variable for GO language.

:: set command line prompt
SET PROMPT=(GO UTF8) $P$G
ECHO Setting the command line prompt for GO language.
